﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using IHISCETeim.DAL;
using IHISCETeim.Model;
using IHISCETeim.Library;
using System.Data;


namespace IHISCETeim.BLL
{
    public class USupplerPartController
    {
        public static int AddInput(USupplerPartInfo obj, string Remark)
        {
            return USupplerPartDAL.AddInput(obj, Remark);
        }
        public static bool Delete(string ItemCode)
        {
            return USupplerPartDAL.Delete(ItemCode);
        }
        public static USupplerPartInfo GetByItemCode(string ItemCode)
        {
            USupplerPartInfo obj = CBO.FillObject<USupplerPartInfo>(USupplerPartDAL.GetByItemCode(ItemCode));
            if (obj == null)
                obj = new USupplerPartInfo();
            return obj;
        }
        public static DataTable GetDetailByItemCode(string ItemCode)
        {
            return USupplerPartDAL.GetDetailByItemCode(ItemCode);
        }
        public static DataTable GetPagination(string ItemCode, string SupplerName, int PageIndex, int PageSize, string Sort, ref int TotalCount)
        {
            return USupplerPartDAL.GetPagination(ItemCode,SupplerName, PageIndex, PageSize, Sort, ref  TotalCount);
        }

    }
}
